import { createRouter, createWebHistory } from 'vue-router';
//导入组件
import LoginVue from '@/views/Login.vue';
import LayoutVue from '@/views/Layout.vue';
import dailymanage from '@/views/book/dailymanage.vue';//``````````````````````````````````````````
import ContractManageVue from '@/views/book/ContractManage.vue';
import ContractDynamicManageVue from '@/views/book/ContractDynamicManage.vue';
import TravelVue from '@/views/book/Travel.vue';
import UserInfoVue from '@/views/user/UserInfo.vue';
import UserResetPasswordVue from '@/views/user/UserResetPassword.vue';
import UserAvatarVue from '@/views/user/UserAvatar.vue';

import clientmanage from '@/views/book/clientmanage.vue';//````````````````````````````````````````
import movemanage from '@/views/book/movemanage.vue';//````````````````````````````````````````
import usermanage from '@/views/book/usermanage.vue';//````````````````````````````````````````
import productionpsmanage from '@/views/book/productionpsmanage.vue';//````````````````````````````````````````
import PersonSchedulVue from '@/views/book/PersonSchedul.vue';
import productionmanage from '@/views/book/productionmanage.vue';//````````````````````````````````````````````````
import areamanage from '@/views/book/areamanage.vue';
import CheckResultVue3 from '@/views/book/clientcome.vue';
import StorageInquiryVue from '@/views/book/StorageInquiry.vue';
import StorageDeclineVue from '@/views/book/StorageDecline.vue';
import QuoteManageVue from '@/views/book/quotemanage.vue';
import companymsgmanage from '@/views/book/companymsgmanage.vue';
import tendermanageVue  from '@/views/book/tendermanage.vue';
import ChanceLogVue from '@/views/book/chancelog.vue';
import ChancePassVue from '@/views/book/chancepass.vue';
import ChanceTraceVue from '@/views/book/chancetrace.vue';

import PayPhaseUpdateVue from '@/views/book/payphaseupdate.vue';
import PayPhaseInputVue from '@/views/book/payphaseinput.vue';
import PayPhaseInquiryVue from '@/views/book/payphaseinquiry.vue';
//定义路由关系
const routes = [
    { path: '/login', component: LoginVue },
    {
        path: '/', component: LayoutVue,
        redirect: '/user/info', //重定向
        children: [
            { path: '/daily/manage', component: dailymanage },//````````````````````````日常管理························
            { path: '/contract/manage', component: ContractManageVue },
            { path: '/contract/dynamic/manage', component: ContractDynamicManageVue },
            { path: '/productionps/manage', component: productionpsmanage },//```````````价格本管理````````````````````
            { path: '/person/schedul', component: PersonSchedulVue },
            { path: '/production/manage', component: productionmanage },//`````````````````产品管理``````````````````````
            { path: '/area/manage', component: areamanage },
            { path: '/client/manage', component: clientmanage },
            { path: '/move/manage', component: movemanage },
            { path: '/user/manage', component: usermanage },
            { path: '/client/come', component: CheckResultVue3 },
            { path: '/storage/inquiry', component: StorageInquiryVue },
            { path: '/storage/decline', component: StorageDeclineVue },
            { path: '/quote/manage', component: QuoteManageVue },
            { path: '/company/msg/manage', component: companymsgmanage },//`````````````````公司信息发布管理```````````````````
            { path: '/travel', component: TravelVue },
            { path: '/user/info', component: UserInfoVue },
            { path: '/user/resetPassword', component: UserResetPasswordVue },
            { path: '/user/avatar', component: UserAvatarVue },
            { path: '/chance/log', component: ChanceLogVue },
            { path: '/chance/pass', component: ChancePassVue },
            { path: '/chance/trace', component: ChanceTraceVue },
            { path: '/tender/manage', component: tendermanageVue },
            { path: '/payphase/updateOughttime', component: PayPhaseUpdateVue },
            { path: '/payphase/add', component: PayPhaseInputVue },
            { path: '/payphase/Inquiry', component: PayPhaseInquiryVue },
        ]
    },
]
//创建路由器
const router = createRouter({
    history: createWebHistory(),
    routes: routes,
})
//导出路由
export default router